module.exports = app => {
    const mongoose = require('mongoose');
    mongoose.connect('mongodb://127.0.0.1:27017/bishe', {
        useNewUrlParser: true,
        useUnifiedTopology: true
    }).then(() => {
        console.log('Connected to database');
    }).catch((error) => {
        console.log('Error connecting to database', error)
    });

    require('require-all')(__dirname + '/../models')
}